from typing import List
from dto.strategy_info import StrategyInfoMetadata
from dto.strategy_assessment import RiskAssessment
from dto.strategy_info import StrategyInfoMetadata
from dto.strategy_stock_day import StrategyStockDay
from service.strategy.base_strategy import BaseStrategy
from service.strategy.base_week_strategy import BaseWeekStrategy


class StrategyPreHandler:

    def analyze(self, trade_info_list: List[StrategyStockDay]) -> RiskAssessment:
        node_point = 0
        description = ""

        return RiskAssessment(
            stock_code=trade_info_list[0].stock_code,
            description=description,
            config=strategy_info,
            node_point=node_point,
        )

    def strategyConfig(self) -> dict:
        """
        返回策略的配置
        """
        return StrategyInfoMetadata(
            strategy_code="PRE_BUILD_STOCK_INFO",
            strategy_name="前置处理,获取股票基础信息",
            strategy_group=9,  # 假设是风险型策略
            strategy_type="BUILD",
            analysis_day=1,
            strategy_level=1,
        )
